package com.qf.controller;

import com.qf.pojo.resp.BaseResp;
import com.qf.service.TrainTicketService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletRequest;

/**
 * @author lipengg
 * @date 2021/10/25
 */
@Api(value = "火车票接口",tags = "火车票接口")
@RestController
@RequestMapping("/train")
public class TrainTicketController {

    @Autowired
    private TrainTicketService trainTicketService;

    @ApiOperation("查看火车票")
    @RequestMapping(value = "buyTicket",method = RequestMethod.GET)
    public BaseResp buyTicket(HttpServletRequest request){
        return trainTicketService.isByTicket();
    }
}
